﻿using Microsoft.Practices.Prism.ViewModel;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.Serialization;
using System.Text;

namespace FridgeManagerApp
{
    [DataContract]
    public class WDeviceOfficeNexus : NotificationObject
    {
        private int nexusUID;
        private int officeUID;
        private int deviceUID;

        [DataMember(Order = 0)]
        public int NexusUID
        {
            get
            {
                return nexusUID;
            }
            set
            {
                nexusUID = value;
                RaisePropertyChanged("NexusUID");
            }
        }

        [DataMember(Order = 1)]
        public int OfficeUID
        {
            get
            {
                return officeUID;
            }
            set
            {
                officeUID = value;
                RaisePropertyChanged("OfficeUID");
            }
        }

        [DataMember(Order = 2)]
        public int DeviceUID
        {
            get
            {
                return deviceUID;
            }
            set
            {
                deviceUID = value;
                RaisePropertyChanged("DeviceUID");
            }
        }

        public WDeviceOfficeNexus()
        {
            NexusUID = -1;
            OfficeUID = -1;
            DeviceUID = -1;
        }

        public WDeviceOfficeNexus(LDeviceOfficeNexus p)
        {
            NexusUID = p.NexusUID;
            OfficeUID = p.OfficeUID;
            DeviceUID = p.DeviceUID;
        }
    }
}
